<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:ui="http://java.sun.com/jsf/facelets"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:p="http://primefaces.org/ui"
      xmlns:f="http://java.sun.com/jsf/core">

    <body>

        <ui:composition template="./TemplatePrincipal.xhtml">

            <ui:define name="top">
                <center>
                    <p:graphicImage value="/img/biblioteca.jpg  " width="1200" height="210"/>
                </center>
            </ui:define>

            <ui:define name="left">
 
              

            </ui:define>

            <ui:define name="content">
                <p:fieldset legend="Login">
                    <h:form>

                        <h:panelGrid columns="3">
                            <center>
                                <h:outputLabel for="usuario" value="usuario: *" />  
                                <p:inputText id="usuario" value="#{accesBean.user}" required="true" label="usuario">  
                                    <f:validateLength minimum="2" />  
                                </p:inputText>  
                                <p:message for="usuario" display="icon"/>  

                                <h:outputLabel for="contrasena" value="Contrasena: *" />                             
                                <p:password id="contrasena" value="#{accesBean.pass}" feedback="true" inline="true"
                                            promptLabel="Por favor introduce tu contraseña" weakLabel="Debil" goodLabel="Buena!!" strongLabel="Excelente!!">  
                                    <f:validateLength minimum="2" />  
                                    <p:ajax update="msgSurname" event="keyup" />  
                                </p:password>
                                <p:message for="contrasena" id="msgSurname" display="icon"/>  

                                <p:commandButton value="Acceder" action="#{accesBean.procesarAccion()}" ajax="false"/>
                            </center>
                            <br></br>
                            <br></br>
                            <br></br>
                            <br></br>
                            <br></br>
                            <br></br>
                            <br></br>
                            <br></br>
                            <br></br>
                            <br></br>
                            <br></br>
                            <br></br>
                        </h:panelGrid>

                    </h:form>
                </p:fieldset>
            </ui:define>

        </ui:composition>

    </body>
</html>
